<#include "/common/layout.html">
<@header>
</@header>
<@body>
<div class="content-wrapper">
  <!-- Content Header (Page header) -->
  <section class="content-header">
    <h1>
      <small>系统管理 > 院校管理</small>
    </h1>
  </section>
  <!-- Main content -->
  <section class="content">
    <!-- Your Page Content Here -->
    <div class="row">
      <div class="col-xs-12">
        <div class="box">
           <form action="${base}/college/list/1" method="post" class="form-inline">
	          <div class="box-header">
	            <div class="input-group">
	            <@shiro.hasPermission name="addCollege">
		            <a class="btn btn-primary dialog" href="javascript:" data-url="${base}/college/add" data-title="添加院校" data-width="850" data-height="550"><i class="fa fa-plus"></i> 添加院校</a>
	            </@shiro.hasPermission>
	            </div>
	            <div class="input-group">
	               <input type="text" name="search" value="${search!}" class="form-control" placeholder="Search">
	               <div class="input-group-btn">
	                 <button class="btn btn-default" type="submit"><i class="fa fa-search"></i></button>
	                 <a href="${base}/college/list/1" class="btn btn-default"><i class="fa fa-refresh"></i></a>
	               </div>
	            </div>
	            <div class="input-group pull-right">
                 <button type="button" class="btn btn-primary btn-flat" onclick="exportTo('院校数据');"><i class="fa fa-file-excel-o"></i> 导出</button>
            </div>
	          </div><!-- /.box-header -->
           </form>
          <div class="box-body table-responsive no-padding">
            <table class="table table-hover">
              <tr>
                <th  width="100px"><input name="colIndex" type="checkbox" class="minimal checkbox-toolbar"> 行号</th>
                <th width="120PX">院校名称</th>
                <th width="80PX">院校类别</th>
                <th width="80PX">学历层次</th>
                <th width="80PX">所属省份</th>
                <th width="200PX">具体地址</th>
                <th width="200PX">操作</th>
              </tr>
              <#list pageData.getRecords() as college>
              	  <tr>
	                <td>
	                   <label>
	                	<input type="checkbox" class="minimal checkbox-item">
	                	${((pageData.current-1)*pageData.size +college_index+1)!}
	                	</label>
	                </td>
	                <td>${(college.collegeName)!}</td>
	                <td>${(college.collegeType)!'--'}</td>
                    <td>${(college.collegeLevel)!'--'}</td>
	                <td>${(college.province)!}</td>
	                <td>${(college.address)!'--'}</td>
	                <td>
	                	<@shiro.hasPermission name="editCollege">
	                	  <a class="btn btn-primary btn-xs dialog" href="javascript:" data-url="${base}/college/edit/${college.collegeId}" data-title="编辑院校" data-width="850" data-height="550">编辑院校</a>
	                	</@shiro.hasPermission>
	             <!--   	<@shiro.hasPermission name="deleteUser">
	                	<a class="btn btn-danger btn-xs"
	                	 data-tiggle="ajax"
	                	 data-submit-url="${base}/system/user/delete?id=${(user.id)!}"
	                	 data-confirm="您确定要删除该条记录吗?">删除</a>
	                	 </@shiro.hasPermission>-->
	                	 
	                	 <a class="btn btn-primary btn-xs dialog" href="javascript:" data-url="${base}/college/addManager/${(college.collegeId)!}" data-title="添加管理员" data-width="850" data-height="550">添加管理员</a>
	                	 <a class="btn btn-primary btn-xs dialog" href="javascript:" data-url="${base}/college/user/list/${(college.collegeId)!}" data-title="查看管理员" data-width="850" data-height="550">查看管理员</a>
	                </td>
	              </tr>
              </#list>
            </table>
          </div><!-- /.box-body -->
          <div class="box-footer row">
            <div class="col-md-6">
         	  <#include "/common/paginateBar.html" />
	  		  <@paginate pageData=pageData actionUrl="${base}/college/list/" urlParas="?search=${search!}&daterange=${daterange!}"  />
            </div>
            <div class="col-md-6 pull-left">
	             <#include "/common/paginate.html" />
	  			 <@paginate currentPage=pageData.getCurrent() totalPage=pageData.getPages() actionUrl="${base}/college/list/" urlParas="?search=${search!}&pageSize=${pageSize!}"  />
            </div>
          </div>
        </div><!-- /.box -->
      </div>
    </div>
  </section><!-- /.content -->
</div><!-- /.content-wrapper -->
</@body>
<@footer>
</@footer>